<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .fater {
            width: 300px;
            height: 149px;
            background-color: pink;
        }
        
        .son {
            width: 200px;
            height: 59px;
            background-color: skyblue;
        }
    </style>
</head>

<body>
    <div class="fater">1
        <div class="son">2</div>
    </div>
    <script>
        var fa = document.querySelector('.fater')
        var son = document.querySelector('.son')
        fa.onclick = function(e) {
            console.log('fa');
            e.stopPropagation()

        }
        son.onclick = function(e) {
            console.log('son');
            e.stopPropagation()


        }
    </script>

</body>

</html>